<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>更改详细资料</title>

<?php include(DEDEMEMBER."/templets/head_inc.htm"); ?>

<script type="text/javascript" language="javascript">
<?php echo GetEnumsJs('nativeplace'); ?>
</script>
<script src="../images/enums.js" type="text/javascript"></script>
<script src="js/webcalendar.js" type="text/javascript"></script>
</head>
<body>
<?php include(DEDEMEMBER."/templets/head.htm"); ?>
<div class="wrapper lineT">
  <div class="mainBox">
    <div class="main">
      <?php include(DEDEMEMBER."/templets/menu.php"); ?>
      <div class="dedeMain">
        <div class="location">设置个人资料</div>
        <div class="titleTabBar bgGreen lineTB">
          <ul>
            <li><a href="mtypes.php">分类管理</a></li>
            <li><a href="flink_main.php">书签管理</a></li>
            <li class="select"><a href="">个人资料</a></li>
          </ul>
        </div>
        <form class="mTB10 mL10 mR10" name="form2" action="edit_fullinfo.php" method="post" onsubmit="return checkSubmit();">
          <input type="hidden" name="dopost" value="save" />
          <div class="titleBar bgGrass lineB mB10">
            <div class="fLeft"><strong>详细资料</strong></div>
            <div class="fRight titSecondary white" style="margin-top:5px;"> <em><a href="edit_baseinfo.php">基本资料</a></em> <em class="mL10 mR10"><a href="edit_space_info.php">空间资料</a></em> <em class="mR10"><a href="edit_fullinfo.php">详细资料</a></em> <em><a href="edit_face.php">用户头像</a></em> </div>
          </div>
          <div class="item info">
            <div class="itemHead bgGrass titleBar" >
              <div class="fLeft"><b>基本资料</b></div>
              <div class="fRight titShow icon16" style="margin-top:5px;"></div>
            </div>
            <div class="itemBody" >
              <table cellspacing="1" class="submit">
                <tbody>
                  <tr>
                    <td width="15%" align="right" valign="top">昵称：</td>
                    <td colspan="3"><input name="uname" type="text" id="uname" size="20" class="text" value="<?php echo $row['uname']; ?>" />
                      (该昵称仅用于交友用途) </td>
                  </tr>
                  <tr>
                    <td align="right" valign="top">目前所在地：</td>
                    <td colspan="3">
                    	<select name="province" id="province" onchange="javascript:selNext(document.getElementById('city'),this.value)">
                        <option value='0'>选择一级地区</option>
             <?php
              $places = GetEnumsTypes($row['place']);
              foreach($em_nativeplaces as $k=>$v)
							{
								if($k%500 == 0)
								{
									if($places['top']==$k) echo "<option value='$k' selected='selected'>$v</option>\r\n";
									else echo "<option value='$k'>$v</option>\r\n";
								}
							}
            ?>
                  </select>
                      &nbsp;
                  <select id="city" name="city">
                  <option value='0'>选择具体地区</option>
            <?php
              if($places['son']>0)
              {
              	foreach($em_nativeplaces as $k=>$v)
								{
									 if($k > $places['top'] && $k < $places['top'] + 500)
									 {
											if($k==$places['son']) echo "<option value='$k' selected='selected'>$v</option>\r\n";
											else echo "<option value='$k'>$v</option>\r\n";
									 }
								}
						  }
            ?>
                    </select>
                    </td>
                  </tr>
                  <tr>
                    <td align="right" valign="top">家乡所在地：</td>
                    <td colspan="3">
             <select name="oldprovince" id="oldprovince" onchange="javascript:selNext(document.getElementById('oldcity'),this.value)">
             <option value='0'>选择一级地区</option>
             <?php
              $places = GetEnumsTypes($row['oldplace']);
              foreach($em_nativeplaces as $k=>$v)
							{
								if($k%500 == 0)
								{
									if($places['top']==$k) echo "<option value='$k' selected='selected'>$v</option>\r\n";
									else echo "<option value='$k'>$v</option>\r\n";
								}
							}
            ?>
                  </select>
                      &nbsp;
                  <select id="oldcity" name="oldcity">
                  <option value='0'>选择具体地区</option>
            <?php
              if($places['son']>0)
              {
              	foreach($em_nativeplaces as $k=>$v)
								{
									 if($k > $places['top'] && $k < $places['top'] + 500)
									 {
											if($k==$places['son']) echo "<option value='$k' selected='selected'>$v</option>\r\n";
											else echo "<option value='$k'>$v</option>\r\n";
									 }
								}
						  }
            ?>
                    </select>
                     </td>
                  </tr>
                  <tr>
                    <td align="right" valign="top">出生日期：</td>
                    <td colspan="3"><input name="birthday" type="text" id="birthday" class="text" value="<?php echo $row['birthday']; ?>" onclick="SelectDate(this,'yyyy-MM-dd',80,0)" />
                    </td>
                  </tr>
                  <tr>
                    <td align="right" valign="top">交友目的：</td>
                    <td width="40%"><?php echo GetEnumsForm('datingtype',$row['datingtype'],'',''); ?></td>
                    <td width="15%" align="right" valign="top">婚姻状况：</td>
                    <td><?php echo GetEnumsForm('marital',$row['marital'],'',''); ?></td>
                  </tr>
                  <tr>
                    <td align="right" valign="top">星座：</td>
                    <td><?php echo GetEnumsForm('star',$row['star'],'',''); ?></td>
                    <td align="right" valign="top">血型：</td>
                    <td><?php echo GetEnumsForm('blood',$row['blood'],'',''); ?></td>
                  </tr>
                  <tr>
                    <td align="right" valign="top">身高：</td>
                    <td><input name='height' type='text' class="text" id='height' style='width:80px' value='<?php echo $row['height']; ?>' />
                      厘米</td>
                    <td align="right" valign="top">体型：</td>
                    <td><?php echo GetEnumsForm('bodytype',$row['bodytype'],'',''); ?></td>
                  </tr>
                  <tr>
                    <td align="right" valign="top">交友宣言：</td>
                    <td colspan="3"><textarea name='lovemsg' style='width:500px;height:45px'><?php echo $row['lovemsg']; ?></textarea>
                    </td>
                  </tr>
                </tbody>
              </table>
            </div>
          </div>
          <div class="item info">
            <div class="itemHead bgGrass titleBar" >
              <div class="fLeft"><b>联系方式</b></div>
              <div class="fRight titShow icon16" style="margin-top:5px;"></div>
            </div>
            <div class="itemBody" >
              <table cellspacing="1" class="submit">
                <tbody>
                  <tr>
                    <td width="15%" align="right" valign="top">联系方式限制：</td>
                    <td colspan="3"><input name="onlynet" type="radio" id="onlynet" value="2" <?php if($row['onlynet']=='2') echo "checked='checked'"; ?> />
                      不公开所有联系方式
                      <input name="onlynet" type="radio" id="onlynet" value="1" <?php if($row['onlynet']=='1') echo "checked='checked'"; ?> />
                      不公开电话、详细地址
                      <input name="onlynet" type="radio" id="onlynet" value="0" <?php if($row['onlynet']=='0') echo "checked='checked'"; ?> />
                      公开所有联系方式 </td>
                  </tr>
                  <tr>
                    <td align="right" valign="top">QQ帐号：</td>
                    <td colspan="3"><input name="qq" type="text" class="text" id="qq" value="<?php echo $row['qq']; ?>" size="15" />
                    </td>
                  </tr>
                  <tr>
                    <td align="right" valign="top">MSN帐号：</td>
                    <td colspan="3"><input name="msn" type="text" id="msn" value="<?php echo $row['msn']; ?>" class="text" />
                    </td>
                  </tr>
                  <tr>
                    <td align="right" valign="top">电话：</td>
                    <td colspan="3"><input name="tel" type="text" id="tel" class="text" value="<?php echo $row['tel']; ?>" />
                    </td>
                  </tr>
                  <tr>
                    <td align="right" valign="top">手机：</td>
                    <td colspan="3"><input name="mobile" type="text" id="mobile" class="text" value="<?php echo $row['mobile']; ?>" />
                    </td>
                  </tr>
                  <tr>
                    <td align="right" valign="top">详细地址：</td>
                    <td colspan="3"><input name="address" type="text" class="text" id="address" style="width:350px" value="<?php echo $row['address']; ?>" />
                    </td>
                  </tr>
                </tbody>
              </table>
            </div>
          </div>
          <div class="item info">
            <div class="itemHead bgGrass titleBar" >
              <div class="fLeft"><b>经济状况</b></div>
              <div class="fRight titHide icon16" style="margin-top:5px;"></div>
            </div>
            <div class="itemBody invisible" >
              <table cellspacing="1" class="submit">
                <tbody>
                  <tr>
                    <td width="15%" align="right" valign="top">收入情况：</td>
                    <td width="40%"><?php echo GetEnumsForm('income',$row['income'],'',''); ?></td>
                    <td width="15%">教育程度：</td>
                    <td><?php echo GetEnumsForm('education',$row['education'],'',''); ?></td>
                  </tr>
                  <tr>
                    <td align="right" valign="top">住房情况：</td>
                    <td><?php echo GetEnumsForm('house',$row['house'],'',''); ?></td>
                    <td>所属行业：</td>
                    <td><?php echo GetEnumsForm('vocation',$row['vocation'],'',''); ?></td>
                  </tr>
                  <tr>
                    <td align="right" valign="top">掌握语言：</td>
                    <td colspan="3"><ul class="picList">
                        <?php
    $arr = $dsql->GetOne("Select * From `#@__sys_set` where sname='language' ");
    $sets = explode(',',$arr['items']);
    $i=0;
    foreach($sets as $v){
    	if(ereg($v,$row['language']))
    	echo "  <li><input type='checkbox' name='language[]' id='language{$i}' value='$v' class='np' checked='checked' />$v</li>\r\n";
    	else
    	echo "  <li><input type='checkbox' name='language[]' id='language{$i}' value='$v' class='np' />$v</li>\r\n";
    	$i++;
    }
    ?>
                      </ul></td>
                  </tr>
                </tbody>
              </table>
            </div>
          </div>
          <div class="item info">
            <div class="itemHead bgGrass titleBar" >
              <div class="fLeft"><b>兴趣爱好</b></div>
              <div class="fRight titHide icon16" style="margin-top:5px;"></div>
            </div>
            <div class="itemBody invisible" >
              <table cellspacing="1" class="submit">
                <tbody>
                  <tr>
                    <td width="15%" align="right" valign="top">是否喝酒：</td>
                    <td width="40%"><?php echo GetEnumsForm('drink',$row['drink'],'',''); ?></td>
                    <td width="15%" align="right" valign="top">是否抽烟：</td>
                    <td><?php echo GetEnumsForm('smoke',$row['smoke'],'',''); ?></td>
                  </tr>
                  <tr>
                    <td align="right" valign="top">兴趣爱好：</td>
                    <td colspan="3"><ul class="picList">
                        <?php
    	$arr = $dsql->GetOne("Select * From `#@__sys_set` where sname='nature' ");
    	$sets = explode(',',$arr['items']);
    	$i=0;
    	foreach($sets as $v){
    		if(ereg($v,$row['nature']))
    		echo "    <li><input type='checkbox' name='nature[]' id='nature{$i}' value='$v' class='np' checked='checked' />$v</li>\r\n";
    		else
    		echo "    <li><input type='checkbox' name='nature[]' id='nature{$i}' value='$v' class='np' />$v</li>\r\n";
    		$i++;
    	}
    	?>
                      </ul></td>
                  </tr>
                </tbody>
              </table>
            </div>
          </div>
          <hr />
          <div style="margin-left:15%">
            <button class="button2" type="submit">更新</button>
            <button class="button2 mL10" type="reset">重设</button>
          </div>
        </form>
      </div>
      <div class="clear"></div>
    </div>
    <div class="clear"></div>
  </div>
</div>
<?php include(DEDEMEMBER."/templets/foot.htm"); ?>
</div>
</body>
</html>
